<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<%@ taglib prefix="s" uri="/struts-tags"%>
<html>
<head>


<meta content="text/html;charset=utf-8" http-equiv="Content-Type">
<meta content="utf-8" http-equiv="encoding">
<title>Techno Bangla - User Home</title>
 <link rel="stylesheet" href="/TECHB/resources/css/style.css" />	
  <script type="text/javascript" src="/TECHB/resources/js/lib/jquery-1.6.4.min.js"></script> 
<script type="text/javascript" src="/TECHB/resources/js/util/util.js"></script>
<script type="text/javascript" src="/TECHB/resources/js/util/numeric.js"></script>
 <script type="text/javascript" src="/TECHB/resources/js/util/util.js"></script>
 
 <link type="text/css" rel="Stylesheet" href="/TECHB/resources/js/lib/jquery.validity.1.2.0/jquery.validity.css" />
        <script type="text/javascript" src="/TECHB/resources/js/lib/jquery.validity.1.2.0/jQuery.validity.js"></script>
 
<script type="text/javascript">

 ///////////////////////////////////////////////////// 
  function loadEarnLeave()
  {
   var dept_ID=document.getElementById("dept_ID").value;
   var grade=document.getElementById("grade").value;
       var url = "GetEarnLeaveInfo.do";
	      $.ajax({
	        type: "GET",
	        url: url,
	        data: "dept_ID="+dept_ID+"&grade="+grade,
	        async: false,
	        dataType:"html",
	        success: function(rsp) {
	         $("#earnLeave").html(rsp);
	        }
		  });
  }
  
 ////////////////////////////////////////////////
 function SubmitRemainEL()
   {
      var allvalues="";
        var tbPosition = document.getElementById('tbl_earnLeave');
        var lastRow = tbPosition.rows.length - 2;
        var i;
        for (i=0; i<lastRow; i++)
        {
          if(document.getElementById('system_id' + i).value!='')
          {
            allvalues+=(document.getElementById('system_id' + i).value+"_1_");
            allvalues+=(document.getElementById('remain_el' + i).value+"_1_");
            allvalues+=(document.getElementById('remain_half_el'+i).value+"_1_");
            allvalues+=(document.getElementById('row_id'+i).value+"_1_");
          }
        }
         document.getElementById('allvalues').value=allvalues;
         //alert(allvalues);
       var url = "SaveEarnLeaveInfo.do";//+getFormAsString("EarnLeaveForm");
          $.ajax({
	        type: "POST",
	        url: url,
	        async: false,
	        dataType:"html",
	        data: getFormAsString("EarnLeaveForm")+new Date(),
	        success: function(rsp) {
	         $("#earnLeave").html(rsp);
	        }
		  });
   } 
   
   
   ////////////////////Ajax Form Submittion

function getFormAsString(formName){
        
	  //Setup the return String
	  returnString ="?";
	        
	  //Get the form values
	  var formElements=document.forms[formName].elements;
	        
	  //loop through the array, building up the url
	  //in the format '/strutsaction.do&name=value'
	 
	  for(var i=formElements.length-1;i>=0; --i ){
	  
	        //we escape (encode) each value
	        returnString+="&" 
	        +escape(formElements[i].name)+"=" 
	        +""+escape(formElements[i].value)+"";
	 }
	 //return the values
	 return returnString; 
}

</script>
 

</head>
<body style="margin: 0px;">

<div style="width: 100%;height: 100px;border-bottom: 1px solid #006219;">
<center>
<div style="width: 1000px;height: 100px;border-right: 1px solid #006219;border-left: 1px solid #006219;">
	<div style="float: left; margin-top: 20px;width: 100px;">
	 <img src="/TECHB/resources/images/bagladesh_logo.gif" width="60" height="60" />
	</div>
	<div style="float: left;margin-left: 30px;color: black;margin-top: 15px;text-align: left;">
	 	<div style="font-size: 27px;font-weight: bold;">Techno Bangla (TECHB)</div>
	 	<div style="font-size: 20px;margin-top: 10px;">Online System</div>
	</div>
</div>
</center>
</div>
<center>
<br/>
<div class="box" style="margin-top: 100px;width: 1000px;text-align: center;">
    <h3>Activities</h3>
    
<form id="StudentMarkSubmission" name="StudentMarkSubmission" method="post" action="StudentMarkSubmission.action">    
    <table width="100%" border="0" cellspacing="1" class="infoTable">
    <tr> 
    </tr>
    <tr>
     <td style="text-align: center" colspan="5">
     	Roll No: <input type="text" id="roll_no" name="roll_no">
     </td>
    </tr>
    <tr>
     <td style="text-align: center" colspan="5">
     	Name: ----------------------------
     <td style="text-align: center" colspan="5">
     	Session: -------------------------
     </td>
    </tr>

    </table>
    
  <table width="100%" border="1" cellspacing="1" class="infoTable">
  <tr>
    <td width="43" rowspan="3">subject</td>
    <td colspan="6">First Term Test </td>
    
  </tr>
  <tr>
    <td width="47">Total Att. </td>
    <td width="20">CT</td>
    <td colspan="4">Hall Test </td>
    
  </tr>
  <tr>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td width="46">MCQ</td>
    <td width="34">CQ</td>
	 <td width="50">TOTAL</td>
	  <td width="42">Grade Total </td>
	   
  </tr>
  <tr>
    <td>Bangali</td>
    <td> <input type="hidden" name="subj_id" id="subj_id" value="1001">
      <input type="text" size="5" name="attendance" id="attendance"/>
    </td>
    <td><input type="text" size="5"  name="ct_marks" id="ct_marks"></td>
    <td><input type="text" size="5"  name="hall_mcq" id="hall_mcq"></td>
	<td><input type="text" size="5"  name="hall_cq" id="hall_cq"></td>
	<td><input type="text" size="5"  name="hall_total" id="hall_total"></td>
	<td><input type="text" size="5"  name="hall_gtotal" id="hall_gtotal"></td>
	   
  </tr>
  <tr>
    <td>English</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
	<td>&nbsp;</td>
	<td>&nbsp;</td>
	<td>&nbsp;</td>
	   
  </tr>
  <tr>
    <td>Physics</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
	<td>&nbsp;</td>
	<td>&nbsp;</td>
	<td>&nbsp;</td>
	   
  </tr>
  <tr>
    <td>Chemistry</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
	<td>&nbsp;</td>
	<td>&nbsp;</td>
	<td>&nbsp;</td>
	   
  </tr>
  <tr>
    <td>Biology</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
	<td>&nbsp;</td>
	<td>&nbsp;</td>
	<td>&nbsp;</td>
	   
  </tr>
  <tr>
    <td>Mathematics</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
	<td>&nbsp;</td>
	<td>&nbsp;</td>
	<td>&nbsp;</td>
	   
  </tr>
  <tr>
    <td>Sports</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
	<td>&nbsp;</td>
	<td>&nbsp;</td>
	<td>&nbsp;</td>
	   
  </tr>
  
</table>
</form>    
    
  
</div>
<p style="height: 30px"></p>
</center>
<script type="text/javascript">
$('input').attr('autocomplete','off');   
</script>
</body>

</html>